import React, { Suspense } from "react";
import { useRoutes } from "react-router-dom";
import { routes } from "./routes";

const RouterView = () => useRoutes(routes);
const Router = () => {
  return (
    <Suspense fallback="路由加载中...">
      <RouterView></RouterView>
    </Suspense>
  );
};

export default Router;
